package com.cr.front.banner.controller;


import com.cr.common.response.JsonResult;
import com.cr.front.banner.pojo.vo.BannerVO;
import com.cr.front.banner.service.BannerService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


import java.util.List;
@Slf4j
@RestController
@RequestMapping("cr/banner/")
@Api(tags = "轮播图模块")
public class BannerController {
    @Autowired
    BannerService bannerService;
    @ApiOperation("查询所有轮播图")
    @GetMapping("select")
    public JsonResult SelectBannerAll(){
        List<BannerVO> list = bannerService.select();
        return JsonResult.success(list);
    }


}
